package ua.eug.robov2;

import com.badlogic.gdx.assets.AssetManager;
import com.badlogic.gdx.graphics.g2d.TextureAtlas;
import com.badlogic.gdx.graphics.g2d.TextureRegion;

public class ImageProvider {

	final static String TextureName = "images.atlas";
	
	private static AssetManager assets = new AssetManager();
	private static TextureAtlas myAtlas;

	public static void Load () {
    	assets.load(TextureName, TextureAtlas.class);
    	assets.finishLoading();
    	myAtlas = assets.get(TextureName, TextureAtlas.class);
	}

	
	public static TextureRegion FindRegion(String name) {
		return myAtlas.findRegion(name);
	}

}
